﻿<UserControl x:Class="OnlineVideos.PersonGallery"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
     xmlns:toolkit="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone.Controls.Toolkit"
     xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    mc:Ignorable="d"
    FontFamily="{StaticResource PhoneFontFamilyNormal}"
    FontSize="{StaticResource PhoneFontSizeNormal}"
    Foreground="{StaticResource PhoneForegroundBrush}"
    d:DesignHeight="480" d:DesignWidth="480"   Loaded="PhoneApplicationPage_Loaded">

    <Grid x:Name="LayoutRoot">
        <Grid.RowDefinitions>
            <RowDefinition Height="*"/>
            <RowDefinition Height="80"/>
        </Grid.RowDefinitions>
        <Grid.Resources>
            <ItemsPanelTemplate x:Key="ItemsPanelTemplate1">
                <toolkit:WrapPanel/>
            </ItemsPanelTemplate>
        </Grid.Resources>
        <Grid x:Name="GalleryGrid" Grid.Row="0">
            <ListBox x:Name="lbxGallery"  ItemsPanel="{StaticResource ItemsPanelTemplate1}"   SelectionChanged="lbxGallery_SelectionChanged">
                <ListBox.ItemTemplate>
                    <DataTemplate>
                        <Border Height="210" Width="140">
                            <Image x:Name="imgGallery"  Source="{Binding Thumbnail}" Height="190" Width="130" Tag="{Binding Title}"/>
                        </Border>
                    </DataTemplate>
                </ListBox.ItemTemplate>
            </ListBox>

            <Canvas>
                <TextBlock Canvas.Top="220" Canvas.Left="80" FontSize="28" x:Name="tblkGallery"  Visibility="Collapsed"/>
            </Canvas>

            <toolkit:PerformanceProgressBar
            VerticalAlignment="Center"
            x:Name="_performanceProgressBargallery" Foreground="White"/>
        </Grid>
        <StackPanel  Name="adstackpl" Grid.Row="1" Orientation="Vertical"  Margin="0,0,0,0" Height="80" >
        </StackPanel>
    </Grid>
</UserControl>
